@extends('common.base-master')

@section('html-head')
    <link rel="stylesheet" type="text/css" href="{{url('css/bootstrap.min.css')}}">
    <link rel="stylesheet" type="text/css" href="{{url('css/enterpriser.css')}}">
@endsection

@section('html-body')
    <main>
        <div class="mainWrapp">
            @include('common.company-section')
            <div class="contain">
                <section class="nav_list">
                    <div>
                        <div class="list">
                            <span class="proList"><button class="clear"></button></span>
                        </div>
                        <div class="search_info">
                            <input type="text" placeholder="请输入您要搜索的信息" />
                        </div>
                        <div class="row">
                            <nav>
                                <ul>
                                    <li><a href="#" class="selected">角色</a></li>
                                    <li><a href="#">地区</a></li>
                                </ul>
                            </nav>

                        </div>
                        <div class="filter-row">
                            <ul class="tab filter-1 hide" data-index="1">
                                @foreach($roles as $role)
                                <li><a href="#" keyword="{{$role->id}}">{{$role->role}}</a></li>
                                @endforeach
                            </ul>
                            <ul class="tab filter-3 hide" data-index="3">
                                <li><a name="district" href="javascript:void(0)" dist_name="">全部</a></li>
                                @foreach(\App\District::all() as $district)
                                    <li><a name="district" keyword="{{$district->dist_name}}" href="javascript:void(0)" dist_name="{{urlencode
                                    ($district->dist_name)}}">{{$district->dist_name}}</a></li>
                                @endforeach
                            </ul>
                        </div>
                    </div>
                </section>
                <section>
                    <h3>项目简介</h3>
                    <p class="count"><em>{{\App\User::whereStatus(1)->whereRole(0)->count()}}</em> \ 筛选结果</p>
                    <div>
                        <ul class="nav_tab nav_title">
                            <li class="desc">创业者简介</li>
                            <li class="stage">角色</li>
                            <li class="type">地区 </li>
                            <li class="address">最近职位</li>
                            <!--<li class="member">操作</li>-->
                        </ul>
                        <div class="content">
                            <ul>
                                @if($users)
                                @foreach($users as $user)
                                    @if($user->userInfo)
                                <li>
                                    <dl>
                                        <dt>
                                            <a href="{{route('Home.Creater.getCreaterDetails',['id'=>$user->id])}}"><img src="{{route('Api.Photo.Show',['id'=>$user->id])}}"
                                                        /></a>
                                        </dt>
                                        <dd class="commpany">
                                            <p><a href="#"><strong>{{$user->userInfo['realname']}}</strong></a></p>
                                            <p>{{$user->userInfo['user_desc']}}</p>
                                        </dd>
                                        <dd class="list">
                                            <div class="list_content">
                                                <p class="stage"><em class="reveal">角色</em><em class="floatR">{{$user->userInfo['position']}}</em></p>
                                                <p class="type"><em class="reveal">地区</em><em class="floatR">{{$user->userInfo['province']}}.{{$user->userInfo['city']}}</em></p>
                                                <p class="address"><em class="reveal">最近职位</em><em  class="floatR">
                                                       {{$user->getUserWorkByUserId($user->id)}}
                                                            </em></p>
                                            </div>
                                        </dd>
                                    </dl>
                                </li>
                                        @endif
                                @endforeach
                                @endif
                                        </ul>
                        </div>
                    </div>
                    <p class="more_bar">查看更多</p>
                </section>
            </div>
        </div>
        <div class="p_pos createProject">
            <!--单选1-->
            <div>
                <p>您还没有项目，现在去创建吧！</p><p>
                    <a href="createpro_f.html"><button>创建项目</button></a>
                    <em class="close"></em>
                </p>
            </div>
            <!--单选2-->
            <div class="p_pos_s" style="display: none;">
                <p>申请融资</p>
                <select>
                    <option>美丽说</option>
                    <option>磨菇街</option>
                </select><br>
                <button>提交项目</button>
                <em class="close"></em>
            </div>
        </div>
        <div class="mirror">123</div>
    </main>
<script>
    var getMore                         = "{{route('Api.Creater.getCreaterMore')}}";
    var showPhoto                       = "{{route('Api.Photo.Show' ,['id'=>0])}}";
    var getDetailById                   = "{{route('Home.Creater.getCreaterDetails',['id'=>0])}}";
    var getSearchMessageByTag           = "{{route('Api.Creater.getSearchMessage')}}";

</script>
    <script src="{{url('js/creater_more.js')}}"></script>
    <script src="{{url('js/enterpriser.js')}}"></script>
@endsection